package com.javase.SY05;

public class Car1 extends Car {
    String manufacturer;

    public Car1(String color, String style, String manufacturer) {
        super(color, style);
        this.manufacturer = manufacturer;
    }

    public Car1(String color) {
        super.color = color;
        this.manufacturer = "上海大众";
    }

    public Car1() {

    }

    public void show(){
        System.out.println("颜色："+color);
        System.out.println("样式："+style);
        System.out.println("生产厂家："+manufacturer);
    }

    public static void main(String[] args) {
        Car1 c1 = new Car1("绿色","轿车","兰博基尼");
        Car1 c2 = new Car1("红色");
        Car1 c3 = new Car1();

        c1.show();
        System.out.println("-----");
        c2.show();
        System.out.println("-----");
        c3.show();
    }
}
